public final class VarBit {
	public static VarBit cache[];
	private boolean aBoolean651;
	public int anInt648;
	public int anInt649;
	public int anInt650;

	public static void unpackConfig(Archive archive) {
		Packet buffer = new Packet(archive.getFile("varbit.dat"));
		int cacheSize = buffer.getUnsignedShort();
		if (VarBit.cache == null) {
			VarBit.cache = new VarBit[cacheSize];
		}
		for (int j = 0; j < cacheSize; j++) {
			if (VarBit.cache[j] == null) {
				VarBit.cache[j] = new VarBit();
			}
			VarBit.cache[j].readValues(buffer);
			if (VarBit.cache[j].aBoolean651) {
				Varp.cache[VarBit.cache[j].anInt648].aBoolean713 = true;
			}
		}
		if (buffer.offset != buffer.buffer.length) {
			System.out.println("varbit load mismatch");
		}
	}

	private void readValues(Packet buffer) {
		do {
			int j = buffer.getUnsignedByte();
			if (j == 0) {
				return;
			}
			if (j == 1) {
				anInt648 = buffer.getUnsignedShort();
				anInt649 = buffer.getUnsignedByte();
				anInt650 = buffer.getUnsignedByte();
			} else if (j == 10) {
				buffer.getString();
			} else if (j == 2) {
				aBoolean651 = true;
			} else if (j == 3) {
				buffer.getInt();
			} else if (j == 4) {
				buffer.getInt();
			} else {
				System.out.println("Error unrecognised config code: " + j);
			}
		} while (true);
	}

	private VarBit() {
		aBoolean651 = false;
	}
}
